﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Linq.Expressions;

namespace Syk.Library.Common
{
    public sealed class VallidationHelper
    {
        public static void ArgumentNotNull<TResult>(Expression<Func<TResult>> expression)
        {
            if (expression.Compile().Invoke() == null)
            {
                throw new ArgumentNullException(expression.Body.Type.FullName);
            }
        }
    }
}
